#!/usr/bin/env python

from unittest import TestCase, main
import sys
sys.path += ['..']
import lattice
import numpy
import random
#from main import main as MN

class test_lattice( TestCase ):
    '''
    my first testing class. Tests lattice class
    '''
    def test_xcombinations(self):
        self.assertEqual(list(lattice.xcombinations([3, 3, 2])), [[0, 0, 0], [0, 0, 1], [0, 1, 0], 
                                                                  [0, 1, 1], [0, 2, 0], [0, 2, 1], 
                                                                  [1, 0, 0], [1, 0, 1], [1, 1, 0], 
                                                                  [1, 1, 1], [1, 2, 0], [1, 2, 1], 
                                                                  [2, 0, 0], [2, 0, 1], [2, 1, 0], 
                                                                  [2, 1, 1], [2, 2, 0], [2, 2, 1]] )
        
        
if __name__ == '__main__':
    main()
